package com.tentact.service;

import com.tentact.dao.DeptDao;
import com.tentact.vo.Department;

import java.util.List;

public class DeptService {
    DeptDao dao =new DeptDao();

    //查询所有部门
    public List<Department> selectAllDept(){
        return dao.selectAllDept();
    }

    //添加部门
    public int insertDept(String Deptname) {
        return dao.insertDept(Deptname);
    }

    //修改部门
    public int updateDept(Department department) {
        return dao.updateDept(department);
    }

    //删除
    public int deleteByDept(int DepartmentId){
        return dao.deleteByDept(DepartmentId);
    }
}
